1. Field of the Invention
The present invention relates to an information recording medium, and a method and an apparatus for managing a defect thereof.
2. Description of the Related Art
A representative information recording medium having a sector structure is an optical disk. Recently, the density and capacity of optical disks have been improved. Therefore, it is important to guarantee the reliability of optical disks.
FIG. 23 shows a logical structure of a conventional optical disk.
As shown in FIG. 23, the optical disk includes two disk information areas 4 and a data recording area 5. The data recording area 5 includes a user area 6 and a spare area 8. The spare area 8 is located radially outward from the user area 6 on the optical disk.
The user area 6 includes a system reservation area 11, a FAT (File Allocation Table) area 12, a root directory area 13, and a file data area 14. The system reservation area 11, the FAT area 12, and the root directory area 13 are collectively referred to as a file management area 10. A first sector of the file management area 10 is located as a sector to which logical sector number "0" (LSN:0) is assigned.
Methods for managing defects of an optical disk are included in ISO/IEC10090 standards (hereinafter, referred Organization of Standardization regarding 90 mm optical disks.
Hereinafter, two methods for managing defects included in the ISO standards are described.
One of the methods is based on a slipping replacement algorithm. The other method is based on a linear replacement algorithm. These algorithms are described in Chapter 19 of the ISO standards.
FIG. 24 is a conceptual view of the conventional slipping replacement algorithm. In FIG. 24, each of the rectangle boxes represents a sector. Characters in each sector represent a logical sector number (LSN) assigned to the sector. The rectangle boxes having an LSN represent normal sectors, and the hatched rectangle box represents a defective sector.
Reference numeral 2401 represents a sequence of sectors including no defective sector in the user area 6, and reference numeral 2402 represents a sequence of sectors including one defective sector in the user area 6.
When a first sector in the user area 6 is a normal sector, LSN:0 is assigned thereto. LSNs are assigned to a plurality of sectors included in the user area 6 in an increasing order from the first sector to which LSN:0 is assigned.
When the user area 6 includes no defective sector, LSN:0 through LSN:m are assigned to the sectors in the user area 6 sequentially from the first sector to a last sector thereof as represented by the sequence of sectors 2401.
If a sector in the sequence of sectors 2401 to which LSN:i is assigned was a defective sector, the assignment of the LSNs is changed so that LSN:i is not assigned to the defective sector but to a sector immediately subsequent to the defective sector. Thus, the assignment of the LSNs are slipped by one sector in the direction toward the spare area 8 from the user area 6. As a result, the last LSN:m is assigned to a first sector in the spare area 8 as represented by the sequence of sectors 2402.
FIG. 25 shows the correspondence between the physical sector numbers and the LSNs after the slipping replacement algorithm described with reference to FIG. 24 is executed. The horizontal axis represents the physical sector number, and the vertical axis represents the LSN. In FIG. 25, chain line 2501 indicates the correspondence between the physical sector numbers and the LSNs when the user area 6 includes no defective sector. Solid line 2502 indicates the correspondence between the physical sector numbers and the LSNs when the user area 6 includes defective sectors I through IV.
As shown in FIG. 25, no LSN is assigned to the defective sectors I through IV. The assignment of the LSNs is slipped in the direction toward an outer portion from an inner portion of the optical disk (i.e., in the increasing direction of the physical sector number). As a result, the LSNs are assigned to a part of the sectors in the spare area 8 which is located immediately after the user area 6.
An advantage of the slipping replacement algorithm is that a delay in access caused by a defective sector is relatively small. One defective sector delays the access merely by a part of the rotation corresponding to one sector. A disadvantage of the slipping replacement algorithm is that the assignment of all the LSNs is slipped after one defective sector. An upper level apparatus such as, for example, a host personal computer identifies sectors by LSNs assigned thereto. When the assignment of the LSNs to the sectors is slipped, the host computer cannot manage user data recorded in the optical disk. Accordingly, the slipping replacement algorithm is not usable after the user data is recorded in the optical disk.
FIG. 26 is a conceptual view of the conventional linear replacement algorithm. In FIG. 26, each of the rectangle boxes represents a sector. Characters in each sector represent a logical sector number (LSN) assigned to the sector. The rectangle boxes having an LSN represent normal sectors, and the hatched rectangle box represents a defective sector.
Reference numeral 2601 represents a sequence of sectors including no defective sector in the user area 6, and reference numeral 2602 represents a sequence of sectors including one defective sector in the user area 6.
If a sector in the sequence of sectors 2601 to which LSN:i is assigned was a defective sector, the assignment of the LSNs is changed so that LSN:i is not assigned to the defective sector. Instead, LSN:i is assigned to, among a plurality of sectors included in the spare area 8, a sector which is unused yet and has a minimum physical sector number (e.g., a first sector of the spare area 8) as represented by the sequence of sectors 2602. Thus, the defective sector in the user area 6 is replaced with a sector in the spare area 8.
FIG. 27 shows the correspondence between the physical sector numbers and the LSNs after the linear replacement algorithm described with reference to FIG. 26 is executed. The horizontal axis represents the physical sector number, and the vertical axis represents the LSN. In FIG. 27, the solid line 2701 indicates the correspondence between the physical sector numbers and the LSNs when the user area 6 includes two defective sectors. The two defective sectors in the user area 6 are replaced by replacing sectors in the spare area 8, respectively.
An advantage of the linear replacement algorithm is that replacement of a defective sector does not influence other sectors since defective sectors and replacing sectors correspond to each other one to one. A disadvantage of the linear replacement algorithm is that a delay in access caused by a defective sector is relatively large. Accessing a replacing sector instead of a defective sector requires a seek operation over a relatively long distance.
As can be appreciated, the advantage and disadvantage of the linear replacement algorithm are converse to the advantage and disadvantage of the slipping replacement algorithm.
FIG. 28 shows an example of assignment of the LSNs to the sectors. In the example shown in FIG. 28, it is assumed that the user area 6 has a size of 100000, the spare area 8 has a size of 10000, and the user area 6 includes four defective sectors.
LSNs are assigned to the sectors in accordance with the slipping replacement algorithm described above.
First, LSN:0, which is a first LSN, is assigned to a sector having a physical sector number:0. Then, LSNs are assigned to the sectors in an increasing order toward an outer portion from an inner portion of the optical disk (i.e., toward the spare area 8 from the user area 6). No LSN is assigned to the defective sectors. The LSN which would be assigned to each defective sector is assigned to a sector immediately subsequent thereto. As a result, the assignment of the LSNs is slipped in the direction toward an outer portion from an inner portion of the optical disk by the number of the defective sectors.
In the example shown in FIG. 28, the user area 6 includes four defective sectors I through IV as described above. LSN:99996 through LSN:99999, which would be assigned to the four sectors I through IV if the four sectors I through IV were not defective, are assigned to four sectors in the spare area 8, respectively, having physical sector numbers of 100000 through 100003. The reason for this is that the assignment of the LSNs is slipped by the number of the defective sectors (four in this example).
In FIG. 28, the sectors in the spare area 8 having the physical sector numbers of 100004 through 109999 are collectively referred to as an "LR spare area". The LR spare area is defined as an area in the spare area 8 to which no LSN is assigned. The LR spare area is used in the linear replacement algorithm as a replacing area.
As shown in FIG. 27, the conventional linear replacement algorithm has a problem in that, when a sector having a small physical sector number is defected as a defective sector, a delay in access caused by the defective sector is relatively large since the distance between the defective sector and the replacing sector is relatively long. Since the file management area 10 located in the vicinity of the sector to which LSN:0 is assigned is accessed each time a file is recorded, a defective sector in the file management area 10 may directly cause undesirable reduction in the access speed to the optical disk. The file management area 10, which is frequently accessed, is expected to have the highest possibility of generating a defective sector.
In order to find the first address of the replacing area (i.e., LR spare area) used in the linear replacement algorithm, the number of sectors by which the assignment of the LSNs is slipped in the slipping replacement algorithm needs to be calculated. The amount of calculation increases as the disk capacity increases.